<template>
  <div class="empty">
    <i class="iconfont bee-xiaolian"></i>
    <div class="emptyText">购物车空空如也</div>
    <van-button class="toIndex" @click="toIndex">前往首页</van-button>
  </div>
</template>

<script>
export default {
  name: 'Empty',
  methods: {
    toIndex() {
      this.$router.push('/home')
    }
  }
}
</script>

<style lang="less" scoped>
@import '../../common/style/mixin.less';
.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 30px;
  .bee-xiaolian {
    font-size: 32px;
    color: @primary;
  }
  .emptyText {
    padding-top: 10px;
    margin-bottom: 15px;
    font-size: 16px;
  }
  .toIndex {
    background-color: @primary;
    color: #fff;
  }
}
</style>